import './assets/main.css'

import { createApp } from 'vue'
import App from './App.vue'
import GlobalCom from './components/GlobalCom.vue'
import router from './router/index.js'
import store from './store'

// 引入axios,vueAxios
import axios from 'axios'
import VueAxios from "vue-axios";

axios.interceptors.request.use((config) =>{
    console.log('config',config);
    config.headers.test = 'test'
    return config
})


const app=createApp(App)

// 注册全局组件
app.component(GlobalCom.name,GlobalCom)

// 注册路由
app.use(router)
// 注册vuex
app.use(store)

// 注册axios
app.use(VueAxios,axios)

app.mount('#app')
